import Vue from 'vue'
import App from './App'
// 图表工具
import * as echarts from 'echarts/core';
import {LineChart, BarChart} from 'echarts/charts';
import {TitleComponent,TooltipComponent,GridComponent, DatasetComponent, TransformComponent, LegendComponent } from 'echarts/components';
// 标签自动布局，全局过渡动画等特性
import {LabelLayout,UniversalTransition} from 'echarts/features';
// 引入 Canvas 渲染器，注意引入 CanvasRenderer 是必须的一步
import {CanvasRenderer} from 'echarts/renderers';

// 按需引入 注册必须的组件
echarts.use([
    LegendComponent,
    TitleComponent,
    TooltipComponent,
    GridComponent,
    DatasetComponent,
    TransformComponent,
    LineChart,
    BarChart,
    LabelLayout,
    UniversalTransition,
    CanvasRenderer
]);




import {
  qqyUtils,
  GetOpenid,
  GetPageInfo
} from "./common/util.js"

Vue.config.productionTip = false
// Vue.prototype.$eventHub = new Vue();

import {
  myRequest,
  BASE_URL
} from './common/api.js'
Vue.prototype.$myRequest = myRequest;
Vue.prototype.$BASE_URL = BASE_URL;
import {lodash} from './common/lodash.js'
Vue.prototype.lodash = lodash;
// main.js
import uView from "uview-ui";
Vue.use(uView);

import tools from '@/common/plugins.tools.js';

import tabbars from "@/components/tabbars.vue"
Vue.component('tabbars', tabbars)

import cxsytabbars from "@/components/cxsy_tabbars.vue"
Vue.component('cxsytabbars', cxsytabbars)

import lmtabbars from "@/components/lmtabbars.vue"
Vue.component('lmtabbars', lmtabbars)

import windtabbars from "@/components/windtabbars.vue"
Vue.component('windtabbars', windtabbars) 

import topBackNavbar from "@/components/top-back-navbar.vue"
Vue.component('top-back-navbar', topBackNavbar)

import topBackNavbarLm from "@/components/top-back-navbar-lm.vue"
Vue.component('top-back-navbar-lm', topBackNavbarLm)


Vue.prototype.$qqyUtils = qqyUtils; 
Vue.prototype.$GetOpenid = GetOpenid;
Vue.prototype.$GetPageInfo = GetPageInfo;
App.mpType = 'app'
/* let pinf = plus.push.getClientInfo(); 
let cid = pinf && pinf.clientid || '';
console.log(pinf,cid); */

const app = new Vue({
  ...App
})

Vue.use(tools, app);

app.$mount()
